<%--
  Created by IntelliJ IDEA.
  User: wanggege
  Date: 2020/8/31
  Time: 7:31 下午
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <link rel="stylesheet" href="../bootstrap/css/bootstrap.min.css">
    <title>登陆——学生信息管理系统</title>
</head>
<style>
    .bodyStyle {
        height: 734px;
        width: 1440px;
        float: left;
        background-repeat: no-repeat;
        background-size: 100% 100%;
        background-attachment: fixed;
        opacity: 0.8;
        background-image: url("../img/bg.jpg")
    }

    .h {
        position: relative;
        margin-top: 200px;
        margin-left: 175px;
        color: aqua;
    }

    .login {
        position: absolute;
        color: aqua;
        width: 250px;
        height: 400px;
        margin-left: 950px;
        margin-top: -150px;

    }
</style>
<body>
<div class="bodyStyle">

    <%
        String msg = (String) request.getAttribute("msg");         // 获取错误属性
        if (msg != null) {
    %>
    <script type="text/javascript" language="javascript">
        alert("<%=msg%>");                                            // 弹出错误信息
        window.location = 'login.jsp';                            // 跳转到登录界面
    </script>
    <%
        }
    %>

    <div class="h">
        <h1>欢迎登录学生信息管理系统</h1>
        <h2>Student Information Manager System</h2>
    </div>

    <div class="login">
        <form class="form-signin" action="userServlet?param=login" method="post">
            <h1 class="h3 mb-3 font-weight-normal" align="center">登录</h1>
            <input name="userName" class="form-control" placeholder="用户名" required value=""><br><br>
            <input type="password" name="password" class="form-control" placeholder="密码" required>
            <input type="checkbox" value="y" name="isLogin">记住密码/自动登录
            <script>

            </script>

            <button class="btn btn-lg btn-primary btn-block mt-3" type="submit" id="login">登 录</button>
            <p class="clearfix">
                <a href="/register" class="float-right">没有账号？去注册</a>
            </p>
            <p class="mt-5 mb-3 text-muted">© WHX</p>
        </form>
    </div>
</div>

</body>
</html>
